{{ if or .GitInfo .Site.Params.BookEditPath }}
<div class="book-footer {{ if not .GitInfo }}justify-end{{ else }}justify-between{{ end }}">
    {{ with .GitInfo }}
    <div>
    {{ $date := .AuthorDate.Local.Format (default "January 2, 2006" $.Site.Params.BookDateFormat) }}
        <a href="{{ $.Site.Params.BookRepo }}/commit/{{ .Hash }}" title='Last modified {{ $date }} by {{ .AuthorName }}' target="_blank" rel="noopener">
            <img src="{{ "svg/calendar.svg" | relURL }}" alt="Changed" /> {{ $date }}
        </a>
    </div>
    {{ end }}
    {{ with .Site.Params.BookEditPath }}
    <div>
    {{ if $.File }}
    {{ $versionArr := split $.File.Path "docs" }}
    {{ $version := replaceRE "docs/([^/]+).*" "$1" $.File.Path}}
    {{ $version := delimit (slice "stable" $version) "-" }}
    {{ $path := index $versionArr 2}}
        <a href="{{ $.Site.Params.BookRepo }}/{{ $version }}/content/{{ $.Site.Language }}/docs{{ $path }}" target="_blank" rel="noopener">
            <img src="{{ "svg/edit.svg" | relURL }}" alt="Edit" />{{ i18n "doc_git_footer"}}
       </a>{{ end }}
    </div>
  {{ end }}
</div>
{{ end }}
<div style="width:100%;margin-top:30px;margin-bottom:30px;">
    <a class="btn btn-primary" id="docPreviousPage">{{ i18n "newer" }}</a>
    <a class="btn btn-primary"id="docNextPage">{{ i18n "older" }}</a>
</div>
